home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 12 / BBS in a box XII-2.iso / Files II / Prog / T / ToolsPlus 2.1.sit / Tools Plus 2.1 ƒ / Tools Plus 2.1 (C & Pascal) / User Manual / 18-Special Routines < prev    next >
Encoding:
Text File  |  1993-10-24  |  8.8 KB  |  328 lines  |  [TEXT/ttxt]

  1. 18  Special Routines
  2. ````````````````````
  3.  
  4.  
  5. Use these routines with caution, or don’t use them!
  6. ```````````````````````````````````````````````````
  7. The following routines should be used with caution, or not at all.  The “comments or special instructions” column often provides an equivalent Tools Plus routine.  It will also explain if the routine can be used in a limited way, or if a Tools Plus equivalent should be used instead.
  8.  
  9. If Inside Macintosh states that the routine should not be called because it is automatically called by the system when it starts up, you need not reference the routine in this section.
  10.  
  11. Some routines that are not listed here can be used, but they will require a pointer to a window.  Your application will have to use Tools Plus’s WindowPointer routine to determine a window’s pointer.
  12.  
  13.  
  14.  
  15.  
  16. Toolbox Routine   Comments or Special Instructions
  17. ```````````````   ``````````````````````````````````````````````````````
  18. AddResMenu        Use AppleMenu
  19.  
  20. AppendMenu        Use Menu
  21.  
  22. BackPat           A window's background pattern should never be changed
  23.                   from white
  24.  
  25. BringToFront
  26.  
  27. CheckItem         Use CheckMenu
  28.  
  29. ClearMenuBar
  30.  
  31. CloseWindow       Use WindowClose
  32.  
  33. DeleteMenu        Use RemoveMenu
  34.  
  35. DelMenuItem       Use RemoveMenu
  36.  
  37. DialogSelect      Modal dialogs are allowed, but a Tools Plus window is
  38.                   easier to use
  39.  
  40. DisableItem       Use EnableMenu
  41.  
  42. DisposeControl    Use with custom controls only
  43.  
  44. DisposeMenu
  45.  
  46. DisposeWindow
  47.  
  48. DlgCopy
  49.  
  50. DlgCut
  51.  
  52. DlgDelete
  53.  
  54. DlgPaste
  55.  
  56. DragControl       Use with custom controls only
  57.  
  58. DragWindow
  59.  
  60. Draw1Control      Use with custom controls only
  61.  
  62. DrawGrowIcon
  63.  
  64. DrawMenuBar       Use UpdateMenuBar
  65.  
  66. EnableItem        Use EnableMenu
  67.  
  68. EventAvail        Your application will intercept some events so that
  69.                   they never reach Tools Plus.  Also note that under
  70.                   MultiFinder and System 7.0 (or later), this routine
  71.                   will switch tasks to other applications and desk
  72.                   accessories.
  73.                      Don’t use this routine unless you really know what
  74.                   you are doing and you thoroughly test your results.
  75.  
  76. FindControl       Done automatically for buttons and scroll bars
  77.  
  78. FindWindow
  79.  
  80. FlashMenuBar
  81.  
  82. FlushEvents       InitToolsPlus flushes all events when Tools Plus is
  83.                   initialized.  You may flush mouse-down, mouse-up, key-
  84.                   down, key-up and auto-key events, as well as
  85.                   application-defined events 1 through 4.  When flushing
  86.                   mouse-up events, you may be disrupting a drag that is
  87.                   already in progress.  If the StillDown function
  88.                   returns true, a drag is in progress, and PollSystem
  89.                   will continue processing the drag until a mouse-up
  90.                   event is encountered.
  91.                      As a rule, don’t use this routine unless you really
  92.                   know what you are doing and you thoroughly test your
  93.                   results.
  94.  
  95. GetCRefCon        Use with custom controls only
  96.  
  97. GetCTitle         Use with custom controls only
  98.  
  99. GetCtlMax         Use with custom controls only.  For scroll bars, use
  100.                   GetScrollBarMax
  101.  
  102. GetCtlMin         Use with custom controls only.  For scroll bars, use
  103.                   GetScrollBarMin
  104.  
  105. GetCtlValue       Use with custom controls only.  For scroll bars, use
  106.                   GetScrollBarVal.  For buttons (check boxes or radio
  107.                   buttons), use ButtonIsSelected
  108.  
  109. GetMenu           No equivalent in Tools Plus because menus can’t be
  110.                   defined as resources.  Use Menu instead.
  111.  
  112. GetNewControl     No equivalent in Tools Plus because buttons and scroll
  113.                   bars can’t be defined as resources.  Use NewButton or
  114.                   NewScrollBar instead.  Can be used for custom
  115.                   controls.
  116.  
  117. GetNewMBar        No equivalent in Tools Plus because menus can’t be
  118.                   defined as resources.  Use Menu instead.
  119.  
  120. GetNewWindow      No equivalent in Tools Plus because windows can’t be
  121.                   defined as resources.  Use WindowOpen instead.
  122.  
  123. GetNextEvent      Your application will intercept events so that they
  124.                   never reach Tools Plus.  Also note that under
  125.                   MultiFinder and System 7.0 (or later), this routine
  126.                   will switch tasks to other applications and desk
  127.                   accessories.
  128.                      Don’t use this routine unless you really know what
  129.                   you are doing and you thoroughly test your results.
  130.  
  131. GetOSEvent        Your application will intercept events so that they
  132.                   never reach Tools Plus.  Also note that under
  133.                   MultiFinder and System 7.0 (or later), this routine
  134.                   will switch tasks to other applications and desk
  135.                   accessories.
  136.                      As a rule, don’t use this routine unless you really
  137.                   know what you are doing and you thoroughly test your
  138.                   results.
  139.  
  140. GrowWindow
  141.  
  142. HideControl       Use with custom controls only
  143.  
  144. HideWindow
  145.  
  146. HiliteControl     Use with custom controls only.  For scroll bars, use
  147.                   EnableScrollBar.  For buttons, use EnableButton.
  148.  
  149. HiliteMenu        Use MenuHilite
  150.  
  151. HiliteWindow
  152.  
  153. InitCursor        Use CursorShape or ResetCursor routines instead
  154.  
  155. InitDialogs
  156.  
  157. InitMenus
  158.  
  159. InitWindows
  160.  
  161. InsertMenu        Use Menu
  162.  
  163. InsertResMenu
  164.  
  165. InsMenuItem       Use InsertMenuItem
  166.  
  167. IsDialogEvent     Modal dialogs are allowed, but a Tools Plus window is
  168.                   easier to use
  169.  
  170. KillControls
  171.  
  172. List Manager      List Manager routines may be incorporated into your
  173.                   application to handle sophisticated lists.  However,
  174.                   the list’s scroll bars must be flagged as “custom
  175.                   controls,” and your application must handle all events
  176.                   pertaining to the list.
  177.  
  178. MenuSelect
  179.  
  180. MoveControl       Use with custom controls only
  181.  
  182. MovePortTo        The co-ordinates may be changed temporarily, providing
  183.                   they are reset prior to calling any Tools Plus routine
  184.  
  185. MoveWindow
  186.  
  187. NewControl        Use with custom controls only.  For scroll bars, use
  188.                   NewScrollBar.  For buttons, use NewButton
  189.  
  190. NewMenu           Use Menu
  191.  
  192. NewWindow         Use WindowOpen
  193.  
  194. OpenDeskAcc
  195.  
  196. SelectWindow      Use ActivateWindow
  197.  
  198. SendBehind
  199.  
  200. SetCRefCon        Use with custom controls only
  201.  
  202. SetCTitle         Use with custom controls only.  For buttons, use
  203.                   ButtonTitle
  204.  
  205. SetCtlMax         Use with custom controls only.  For scroll bars, use
  206.                   SetScrollBarMax
  207.  
  208. SetCtlMin         Use with custom controls only.  For scroll bars, use
  209.                   SetScrollBarMin
  210.  
  211. SetCtlValue       Use with custom controls only.  For scroll bars, use
  212.                   SetScrollBarVal.  For buttons (check boxes or radio
  213.                   buttons), use SelectButton.
  214.  
  215. SetCursor         Use CursorShape or ResetCursor routines instead
  216.  
  217. SetEventMask      Upon startup, key-up events are disabled.  Do not
  218.                   disable the following events: mouseDown, MouseUp,
  219.                   keyDown, autoKey, updateEvt, activateEvt, and app4Evt
  220.  
  221. SetItem           Use RenameItem
  222.  
  223. SetItemIcon
  224.  
  225. SetItemMark       Use MenuMark
  226.  
  227. SetItemStyle      Use MenuStyle
  228.  
  229. SetMenuBar
  230.  
  231. SetOrigin         The co-ordinates may be changed temporarily, providing
  232.                   they are reset prior to calling any Tools Plus routine
  233.  
  234. SetWTitle         Use WindowTitle
  235.  
  236. ShowControl       Use with custom controls only
  237.  
  238. ShowHide
  239.  
  240. ShowWindow
  241.  
  242. SizeControl       Use with custom controls only
  243.  
  244. SizeWindow
  245.  
  246. SpaceExtra        SpaceExtra must be set to 0, the initial value, when
  247.                   calling any Tools Plus routine
  248.  
  249. SystemClick
  250.  
  251. SystemEdit
  252.  
  253. SystemEvent
  254.  
  255. SystemMenu
  256.  
  257. TEActive          Use ActivateField
  258.  
  259. TEAutoView
  260.  
  261. TECalc
  262.  
  263. TEClick           Use ClickInField
  264.  
  265. TECopy
  266.  
  267. TECut
  268.  
  269. TEDeactivate      Use DeactivateField
  270.  
  271. TEDelete
  272.  
  273. TEDispose         Use DeleteField
  274.  
  275. TEFromScrap
  276.  
  277. TEGetText         Use GetFieldString
  278.  
  279. TEIdle            Called in SystemTasks
  280.  
  281. TEInit
  282.  
  283. TEInsert
  284.  
  285. TEKey
  286.  
  287. TENew             Use NewField
  288.  
  289. TEPaste
  290.  
  291. TEPinScroll
  292.  
  293. TEScroll
  294.  
  295. TESelect
  296.  
  297. TESelView
  298.  
  299. TESetJust
  300.  
  301. TESetText
  302.  
  303. TEToScrap
  304.  
  305. TEUpdate
  306.  
  307. TrackBox
  308.  
  309. TrackControl      Done automatically for buttons and scroll bars
  310.  
  311. TrackGoAway
  312.  
  313. UnloadSeg         Do not unload the segments containing Tools Plus’s
  314.                   libraries
  315.  
  316. UpdtControl
  317.  
  318. WaitNextEvent     Your application will intercept events so that they
  319.                   never reach Tools Plus.  Also note that under
  320.                   MultiFinder and System 7.0 (or later), this routine
  321.                   will switch tasks to other applications and desk
  322.                   accessories.
  323.                      Don’t use this routine unless you really know what
  324.                   you are doing and you thoroughly test your results.
  325.  
  326. ZoomWindow
  327.  
  328.